package models

import "gorm.io/gorm"

//视频结构体

type Video struct {
	gorm.Model
	Title     string    `gorm:"type:varchar(50)" json:"title"`
	Content   string    `gorm:"type:varchar(50)" json:"content"`
	VideoImg  string    `gorm:"type:varchar(255)" json:"videoImg"`
	Cate      uint      `gorm:"type:int(255)" json:"cate"`
	VideoCate VideoCate `gorm:"foreignKey:Cate"`
}

//分类

type VideoCate struct {
	gorm.Model
	Name string `gorm:"type:varchar(30)" json:"name"`
}
